<aside>
    {% if connected %}
        <p>Connecté(e) en tant que <strong>{{ last_username }}</strong>.</p>
        <ul>
            {% for link, label in links %}
                <li><a href="{{ path(link) }}">{{ label }}</a></li>
            {% endfor %}
        </ul>
    {% else %}
        {% if error %}
            <div>{{ error.message }}</div>
        {% endif %}
        <form action="{{ path('LPCISIIPHP2012Bundle_login_check') }}" method="post">
            <label for="username">Login</label>
            <input type="text" id="username" name="login" value="{{ last_username }}" />

            <label for="password">Mot de passe</label>
            <input type="password" id="password" name="mdp" />

            {#
                If you want to control the URL the user is redirected to on success (more details below)
                <input type="hidden" name="_target_path" value="/account" />
            #}

            <input type="submit" name="connection" />
        </form>
            <br>
        <ul>
            <li><a href="{{ path('LPCISIIPHP2012Bundle_cart') }}">Panier</a></li>
	    <li><a href="{{ path('LPCISIIPHP2012Bundle_inscription') }}">Inscription</a></li>
        </ul>
    {% endif%}
</aside>
